package org.recruit.system.service.impl;

import java.util.List;

import org.recruit.system.domain.Companyintroduction;
import org.recruit.system.mapper.CompanyintroductionMapper;
import org.recruit.system.service.ICompanyintroductionService;
import org.recruit.system.utils.Convert;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;


/**
 * 企业简介Service业务层处理
 *
 * @author teapot
 * @date 2020-11-12
 */
@Service
public class CompanyintroductionServiceImpl implements ICompanyintroductionService {
    @Autowired
    private CompanyintroductionMapper companyintroductionMapper;

    /**
     * 查询企业简介
     *
     * @param id 企业简介ID
     * @return 企业简介
     */
    @Override
    public Companyintroduction selectCompanyintroductionById(Long id) {
        return companyintroductionMapper.selectCompanyintroductionById(id);
    }

    /**
     * 查询企业简介列表
     *
     * @param companyintroduction 企业简介
     * @return 企业简介
     */
    @Override
    public List<Companyintroduction> selectCompanyintroductionList(Companyintroduction companyintroduction) {
        return companyintroductionMapper.selectCompanyintroductionList(companyintroduction);
    }

    /**
     * 新增企业简介
     *
     * @param companyintroduction 企业简介
     * @return 结果
     */
    @Override
    public int insertCompanyintroduction(Companyintroduction companyintroduction) {
        return companyintroductionMapper.insertCompanyintroduction(companyintroduction);
    }

    /**
     * 修改企业简介
     *
     * @param companyintroduction 企业简介
     * @return 结果
     */
    @Override
    public int updateCompanyintroduction(Companyintroduction companyintroduction) {
        return companyintroductionMapper.updateCompanyintroduction(companyintroduction);
    }

    /**
     * 删除企业简介对象
     *
     * @param ids 需要删除的数据ID
     * @return 结果
     */
    @Override
    public int deleteCompanyintroductionByIds(String ids) {
        return companyintroductionMapper.deleteCompanyintroductionByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除企业简介信息
     *
     * @param id 企业简介ID
     * @return 结果
     */
    @Override
    public int deleteCompanyintroductionById(Long id) {
        return companyintroductionMapper.deleteCompanyintroductionById(id);
    }
}
